<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1,maximum-scale=1,user-scalable=no">
    <title>我的</title>
    <link rel="stylesheet" href="__CSS__/mui-3.6.1.min.css">
    <link rel="stylesheet" href="__CSS__/my.css">
</head>
<body>
<div class="my-bg">
    <div class="round-photo-position round-photo-shadow">
       <!--  <img class="round-photo" src="<if condition="$uinfo['userPhoto']" >/{$uinfo['userPhoto']}<else/>__IMG__/member.jpg</if>"  onclick="location.href='<if condition="$uinfo['userId']">/Wx/Login/userInfo<else/>/Wx/Login/
       login</if>'" /> -->
                <?php   if($uinfo['userPhoto']== ''){  ?>
        <img class="round-photo" src="__IMG__/member.jpg" onclick="location.href='<if condition="$uinfo['userId']">/Wx/Login/userInfo<else/>/Wx/Login/login</if>'"/>
        <?php }elseif(strpos($uinfo['userPhoto'],"http://") === 0){  ?>
        <img class="round-photo" src="{$uinfo['userPhoto']}" onclick="location.href='<if condition="$uinfo['userId']">/Wx/Login/userInfo<else/>/Wx/Login/login</if>'"/>

        <?php }elseif(substr($uinfo['userPhoto'],7) != 'http://'){  ?>
        <img class="round-photo" src="__ROOT__/{$uinfo['userPhoto']}" onclick="location.href='<if condition="$uinfo['userId']">/Wx/Login/userInfo<else/>/Wx/Login/login</if>'"/>
        <?php
    }
    ?>
    </div>
    <div class="user-name">
        <if condition="$uinfo['userName']">{$uinfo.userName}
        <else/>{$uinfo.userPhone}</if>
    </div>
    <div class="kkk" onclick="location.href='/Wx/Login/userInfo'"><img src="__IMG__/kkk.png"/></div>
</div>
<div class="horizontal-view my-menu-wrap">
    <div onclick="goUinfo('/Wx/Ucenter/wallet/r/my.html')" class="mui-table-view-cell vertical-view my-menu-item">
        <img src="__IMG__/my_balance.png" width="28px" height="20px"/>
        <div class="line-name">我的余额</div>
        <div class="line-number">￥{$uinfo['userMoney']|default=0}</div>
    </div>
    <img src="__IMG__/gray_line_gap.png" width="2" height="50px"/>
    <div onclick="goUinfo('/Wx/Coupon/my_coupon/r/my.html')" class="mui-table-view-cell vertical-view my-menu-item">
        <img src="__IMG__/my_coupon.png" width="26px" height="20px"/>
        <div class="line-name">我的优惠券</div>
        <div class="line-number">{$coupon|default=0}</div>
    </div>
    <img src="__IMG__/gray_line_gap.png" width="2" height="50px"/>
    <div onclick="goUinfo('/Wx/Score/index/r/my.html')" class="mui-table-view-cell vertical-view my-menu-item">
        <img src="__IMG__/my_score.png" width="20px" height="20px"/>
        <div class="line-name">积分</div>
        <div class="line-number">{$uinfo['userScore']|default=0}</div>
    </div>
</div>

<ul class="mui-table-view no-line-before no-line-after" style="margin-top: 10px">
    <li class="mui-table-view-cell gray-line-after">
        <a class="mui-navigate-right login" href="/Wx/Address/myAddr">
            <div class="mui-media-body">
                <img class="left-icon" src="__IMG__/my_address.png">
                收货地址
            </div>
        </a>
    </li>
    <li class="mui-table-view-cell gray-line-after" style="display: none;">
        <a class="mui-navigate-right login" href="javascript:void(0)">
            <div class="mui-media-body">
                <img class="left-icon" src="__IMG__/my_wei_bang.png">
                我的微帮
            </div>
        </a>
    </li>
    <li class="mui-table-view-cell no-line-after">
        <a class="mui-navigate-right login" href="/Wx/Favorites/index">
            <div class="mui-media-body">
                <img class="left-icon-2" src="__IMG__/my_collection.png">
                我的收藏
            </div>
        </a>
    </li>

    <li class="li-gap"></li>
    <li class="mui-table-view-cell no-line-after">
        <a class="mui-navigate-right" href="/Wx/coupon/coupon_center">
            <div class="mui-media-body">
                <img class="left-icon" src="__IMG__/my_balance.png">
                领取优惠券
            </div>
        </a>
    </li>


    <li class="li-gap"></li>
    <li class="mui-table-view-cell no-line-after">
        <a class="mui-navigate-right" href="/Wx/Score/scoreShop">
            <div class="mui-media-body">
                <img class="left-icon" src="__IMG__/my_score_shop.png">
                积分商城
            </div>
        </a>
    </li>
    <li class="li-gap"></li>
    <li class="mui-table-view-cell gray-line-after">
        <a class="mui-navigate-right login" href="/Wx/Join/protocol">
            <div class="mui-media-body">
                <img class="left-icon" src="__IMG__/my_shop_join.png">
                商家入驻
            </div>
        </a>
    </li>
    <li class="mui-table-view-cell gray-line-after">
        <a class="mui-navigate-right " href="/Wx/Service/index">
            <div class="mui-media-body">
                <img class="left-icon" src="__IMG__/my_service_center.png">
                服务中心
            </div>
        </a>
    </li>
    <li class="mui-table-view-cell no-line-after" style="display: none;">
        <a class="mui-navigate-right" href="javascript:void(0)">
            <div class="mui-media-body">
                <img class="left-icon" src="__IMG__/my_about.png">
                关于人汇O2O商城
            </div>
        </a>
    </li>
</ul>
<div style="height: 45px;"></div>
<input id="isLoign" type="hidden" value="<if condition="$userInfo['userId']">1<else/>0</if>" />

<!--<script src="__JS__/mui-3.6.1.min.js"></script>-->
<script>
window.onload = function(){
    if(document.getElementById('isLoign').value==0){
        var aTag=document.getElementsByClassName('login');
        for(var i in aTag){
            aTag[i].href = 'javascript:mui.toast("请先登录");location.href="/Wx/Login/userInfo"';
        }
    }
}

function goUinfo(url){
    if(document.getElementById('isLoign').value==0){
        mui.toast('请先登录');
        location.href='/Wx/Login/userInfo';
        return;
    }
    location.href=url;
}
</script>
</body>
</html>